﻿using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Edutainment
{
    public class AppManager
    {
        public SortationController sortController { get;  set; }
        public StorageController storageController { get;  set; }
        public ButtonController buttonController { get;  set; } 

        public AppManager()
        {
            storageController = new StorageController();

            ArrayList lastState = storageController.deserializeState();

            if (lastState != null && lastState.Count > 0)
            {
                sortController = new SortationController(lastState);
            }
            else
            {
                sortController = new SortationController();
            }

            buttonController = new ButtonController();
        }
    }
}
